Skip to content

#4107 inline status dropdown#4141

Open
cielbellerose wants to merge 6 commits intodevelopfrom
#4107-maintenance-bom-inline-editing
Open

#4107 inline status dropdown#4141
cielbellerose wants to merge 6 commits intodevelopfrom
#4107-maintenance-bom-inline-editing

Conversation

@cielbellerose
Copy link
Copy Markdown
Contributor

@cielbellerose cielbellerose commented Apr 9, 2026

Changes

BOM inline editing

  • All fields except Subtotal can be edited inline
  • Subtotal updates when quantity or price change

Notes

Removed the 'None' special handling for PDM file name to make inline editing more intuitive (None vs empty it was just a bit odd to handle inline)

Test Cases

  • Subtotal updates when quantity or price change
  • price & quantity cannot be negative
  • name trimmed cannot be empty
  • material type is required, no empty dropdown option

Screenshots

Screenshot 2026-04-08 at 8 30 49 PM Screenshot 2026-04-11 at 9 09 24 AM Screenshot 2026-04-11 at 9 10 13 AM Screenshot 2026-04-11 at 9 10 29 AM Screenshot 2026-04-11 at 9 45 13 AM

Checklist

It can be helpful to check the Checks and Files changed tabs.
Please review the contributor guide and reach out to your Tech Lead if anything is unclear.
Please request reviewers and ping on slack only after you've gone through this whole checklist.

  • All commits are tagged with the ticket number
  • No linting errors / newline at end of file warnings
  • All code follows repository-configured prettier formatting
  • No merge conflicts
  • All checks passing
  • Screenshots of UI changes (see Screenshots section)
  • Remove any non-applicable sections of this template
  • Assign the PR to yourself
  • No yarn.lock changes (unless dependencies have changed)
  • Request reviewers & ping on Slack
  • PR is linked to the ticket (fill in the closes line below)

Closes #4107

@cielbellerose cielbellerose linked an issue Apr 9, 2026 that may be closed by this pull request
3 tasks
@cielbellerose cielbellerose self-assigned this Apr 9, 2026
@cielbellerose cielbellerose marked this pull request as ready for review April 11, 2026 14:12
@cielbellerose cielbellerose requested review from Steph375, chpy04 and wavehassman and removed request for Steph375, chpy04 and wavehassman April 11, 2026 14:23
Copy link
Copy Markdown
Contributor

@wavehassman wavehassman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great job Kinsey! I'm fine with taking subtotal out of the backend endpoint and calculating it in the service function, but if we're going to do that, I want to take it out everywhere in the frontend and other places. If someone were to go back later, it would be pretty confusing to have it in some places but not others.

quantity,
unitName,
price,
subtotal,
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you have to take subtotal out of the route too

manufacturer = await BillOfMaterialsService.getSingleManufacturerWithQueryArgs(manufacturerName, organization);
}

// recalculate subtotal on edits
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

if we're going to take subtotal out of the endpoints in the backend, we should take it out of the frontend hooks too since now it's being passed and then dropped


const processRowUpdate = async (newRow: BomRow, oldRow: BomRow): Promise<BomRow> => {
// assemblies are not editable
if (String(newRow.id).startsWith('assembly')) return newRow;
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

id is already a string in the BomRow type so casting it is unecessary

renderCell: renderStatusBOM,
renderCell: (params) => {
// assemblies are not editable
if (!params.value || String(params.row.id).startsWith('assembly')) return null;
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

same thing here

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Maintenance] - BOM Inline Editing

2 participants